<?php

namespace App\Http\Requests\Admin\Collection;

use App\Http\Requests\Request;

class CollectionAccountRequest extends Request{
    public function authorize(){
        return true;
    }

    public function rules(){
        return [
            'url' => 'required|url',
            'username' => 'required',
            'password' => 'required',
            'source' => 'required',
        ];
    }

    public function messages(){
        return [
            'url.required' => 'url采集地址不能为空',
            'url.url' => '采集地址必须是有效URL',
            'username.required' => '用户名不能为空',
            'password.required' => '密码不能为空',
            'source.required' => '来源地址不能为空',

        ];
    }
}